import { useDispatch, useSelector } from 'react-redux';
import './App.css';
import { decrement, increment } from './features/auth/auth';

function App() {
  const count = useSelector((state) => state.auth.count);
  const dispatch = useDispatch();
  return (
    <div className="App">
      <button aria-label="Increment value" onClick={() => dispatch(increment())}>
        Increment
      </button>
      <span>{count}</span>
      <button aria-label="Decrement value" onClick={() => dispatch(decrement())}>
        Decrement
      </button>
    </div>
  );
}

export default App;
